package com.ziyun.erp.modules.goods.service;

import com.baomidou.mybatisplus.plugins.Page;
import com.baomidou.mybatisplus.service.IService;
import com.ziyun.erp.modules.goods.TwbVo.TwbEditPriceVo;
import com.ziyun.erp.modules.goods.TwbVo.TwbGoodsVo;
import com.ziyun.erp.modules.goods.TwbVo.TwbStateCollectVo;
import com.ziyun.erp.modules.goods.VO.FastPriceVo;
import com.ziyun.erp.modules.goods.VO.PrintPriceVo;
import com.ziyun.erp.modules.goods.VO.VerifyPriceVo;
import com.ziyun.erp.modules.goods.entity.GoodsEntity;
import com.ziyun.erp.modules.goods.entity.GoodsOptionEntity;
import com.ziyun.erp.modules.goods.entity.QuoteVO;
import com.ziyun.erp.modules.supp.entity.SellerInfoEntity;
import io.renren.common.utils.PageUtils;
import io.renren.common.utils.R;

import java.util.List;
import java.util.Map;

/**
 * 商品表
 *
 * @authorxueqz
 * @email
 * @date 2018-08-21 08:46:29
 */
public interface GoodsService extends IService<GoodsEntity> {

    PageUtils queryPage(Map<String, Object> params);

    R getAllGoodsProperty(Long goodsId, Integer sellerId);

    Page<GoodsEntity> queryGoodsPage(Page<GoodsEntity> page, Map<String, Object> params);

    List<GoodsEntity> getGoodsByIds(String relateDesignIds);

    PageUtils queryPageNew(Map<String, Object> params);

    void addDesign(Integer goodId, Integer designId);

    void pushGood(GoodsEntity goods);

    void updateGoods(GoodsEntity goods, Long userId);

    void updateStatus(Long goodsId, String status, Long userId);

    void pushQuoteGood(QuoteVO quoteVO);

    Map<String, Object> getAttributeAndCraftData(GoodsEntity goodsProperty);

    List<GoodsOptionEntity> getOptionsByGoodsId(Long goodsId);

    void pushChainGoods(GoodsEntity goods, List<SellerInfoEntity> sellerInfoEntities);

    void pushChainQuoteGood(QuoteVO quoteVO1, List<SellerInfoEntity> sellerInfoEntities);

    void loadAllGoodsCacheEvent();

    void solveBug();

    String verifyCraftPrice(VerifyPriceVo verifyPriceVo, Long sellerId);

    String quotePrice(String ids, Integer sellerId);

    String verifyPrintPrice(PrintPriceVo printPriceVo, Integer factoryId);

    void editQuoteGood(QuoteVO quoteVO);

    String verifyFastPrice(List<FastPriceVo> fastPriceVoList, Integer sellerId);

    void loadGoodsCacheEvent(Long goodsId);

    void hideGoods(Long goodsIds, Long userId);

    void opMarkGoodsByGoodsId(Integer goodsId, Boolean mark);

    void examineGoods(Integer goodsId, Integer examine);

    void frozenGoods(Long sellerId, String frozenName);

    void unfreezeGoods(Long sellerId, String unfreezeName);

    /**
     * 商品远程搜索goods/goodsrecommend
     * @param params lu
     * @return
     */
    List<GoodsEntity> selectGoodsList(Map<String, Object> params);

    List<Map<String, Object>> selectPushList();

    R getTwbGoodsVoList(List<Integer> goodsIds,Integer freightId);

    R getTwbGoodsVo(Long goodsId);

    R getUnitLibrary();

    void pushTwbGoodsVoList(List<TwbGoodsVo> list ,String userName);

    R getTwbGoodsList(Map params);

    R editTwbGoodsPrice(Long goodsId);

    R goodsTwbUpdate(GoodsEntity goods);

    R saveTwbGoodsListPrice(List<TwbEditPriceVo> list);

    R getTwbCateAndGoods(Long sellerId);

    List<Long> handHide(Integer categoryId, Boolean hide);

    R twbListOperation(List<Long> goodsIds,String marketable);

    void twbGoodsEvent(List<TwbGoodsVo> list);

    void twbGoodsImageBug();

    TwbStateCollectVo getTwbGoodsStateCount(Long sellerId);

    void pushTwbGoodsVoListNewVersions(List<TwbGoodsVo> list, String userName,Long sellerId);
}
